package com.icangya.DAO.impl;

import com.icangya.DAO.IGiveMoneyRecordDAO;
import com.icangya.domain.GiveMoneyRecord;
import org.springframework.stereotype.Repository;

import java.util.List;


@Repository
public class GiveMoneyRecordDAOImpl extends  BaseDAO<GiveMoneyRecord> implements IGiveMoneyRecordDAO{

    @Override
    public List getGiveMoneyStatus(String openId) {

        String hql="FROM GiveMoneyRecord gm where gm.status=0 and gm.openId=?";
       List<GiveMoneyRecord> list= (List<GiveMoneyRecord>) getHibernateTemplate().find(hql,openId);
        if(list.size()>0)
            return list;
        return null;
    }


}
